package com.bole.feign;

import com.bole.dto.car.TbCarDto;
import com.bole.dto.img.TbCarImgDto;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.*;

import java.util.List;

@FeignClient(value = "BOLECAR-BACKSTAGE-SERVICE")
public interface TbCarImgFeign {
    @GetMapping("/img/getImgInfo")
    List<TbCarImgDto> getImgInfo();
    @PostMapping("/img/saveImgInfo")
    void saveImgInfo( @RequestBody TbCarImgDto tbCarImgDto);
    @PostMapping("/img/toUpdate")
    TbCarImgDto toUpdate(@RequestParam("id") Long id);
    @PostMapping("/img/updateImgInfo")
    void updateImgInfo( @RequestBody TbCarImgDto carImgDto);
    @PostMapping("/img/deleteBatch")
    void deleteBatch(@RequestParam("idss") List<Long> idss);

    //通过汽车id查询
    @PostMapping("/img/findByCarId")
    TbCarImgDto findByCarId(@RequestParam("carId") Long carId);

    @PostMapping("/img/getCarImgById")
    TbCarImgDto getCarImgById(@RequestParam("carId")Long carId);
}
